using System;
using System.Windows.Forms;
using System.Drawing;

namespace HIS
{
    public class InfectiousDiseaseForm : Form
    {
        private TextBox txtReportInfo;
        private Button btnSubmit;
        private DataGridView dgvReportStatus;

        public InfectiousDiseaseForm()
        {
            InitializeComponents();
        }

        private void InitializeComponents()
        {
            // 窗体设置
            this.Text = "传染病电子报卡";
            this.Size = new Size(800, 600);
            this.StartPosition = FormStartPosition.CenterScreen;

            // 报卡信息输入区域
            GroupBox gbReportInfo = new GroupBox
            {
                Text = "报卡信息",
                Location = new Point(10, 10),
                Size = new Size(780, 300)
            };

            txtReportInfo = new TextBox
            {
                Location = new Point(10, 25),
                Size = new Size(760, 265),
                Multiline = true
            };

            gbReportInfo.Controls.Add(txtReportInfo);

            // 提交按钮
            btnSubmit = new Button
            {
                Text = "提交报卡",
                Location = new Point(10, 320),
                Size = new Size(100, 30)
            };

            // 报卡状态显示区域
            GroupBox gbReportStatus = new GroupBox
            {
                Text = "报卡状态",
                Location = new Point(10, 360),
                Size = new Size(780, 220)
            };

            dgvReportStatus = new DataGridView
            {
                Location = new Point(10, 25),
                Size = new Size(760, 185),
                AllowUserToAddRows = false,
                AllowUserToDeleteRows = false,
                ReadOnly = true,
                SelectionMode = DataGridViewSelectionMode.FullRowSelect
            };

            // 添加列
            dgvReportStatus.Columns.AddRange(new DataGridViewColumn[] {
                new DataGridViewTextBoxColumn { Name = "报卡时间", HeaderText = "报卡时间", Width = 150 },
                new DataGridViewTextBoxColumn { Name = "疾病名称", HeaderText = "疾病名称", Width = 150 },
                new DataGridViewTextBoxColumn { Name = "患者姓名", HeaderText = "患者姓名", Width = 100 },
                new DataGridViewTextBoxColumn { Name = "报卡状态", HeaderText = "报卡状态", Width = 100 },
                new DataGridViewTextBoxColumn { Name = "审核结果", HeaderText = "审核结果", Width = 100 }
            });

            gbReportStatus.Controls.Add(dgvReportStatus);

            // 添加控件到窗体
            this.Controls.AddRange(new Control[] {
                gbReportInfo,
                btnSubmit,
                gbReportStatus
            });
        }
    }
} 